<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<link rel="stylesheet" type="text/css" href="../../_third-party/bootstrap/bootstrap.css" />
		<link rel="stylesheet" type="text/css" href="../../_src/com.alert/alert.css" />
		<link rel="stylesheet" type="text/css" href="../../_src/wm-custom.css" />
		<link rel="stylesheet" type="text/css" href="../../_src/navigation/tabs.css" />
	</head>
	<body>
		<div id="myTab"></div>
		<div id="myTab2"></div>
		<div id="content"></div>
		
		<script src="../../_third-party/jQuery/jquery-1.9.1.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../_third-party/bootstrap/bootstrap.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../_src/com.alert/alert.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../_src/wm-custom.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../_src/navigation/tabs.js" type="text/javascript" charset="utf-8"></script>
		<script>
			$(function() {
				// 初始化
			
				$('#myTab').wmTabs({
					list: [{
						'id': 'a1',
						'title': '首页',
						'close': true
					}, {
						'id': 'a2',
						'title': '首页1',
						'close': true
					}, {
						'id': 'a3',
						'title': '首页2',
						'close': true
					}],
					idKey: "id",
					textKey: "title",
					addApi: "suc.json",
					removeApi: "suc.json",
					content: $("#content")
				})
			
				$('#myTab2').wmTabs({
					list: [{
						'id': 'b1',
						'title': '首页',
						'close': true
					}, {
						'id': 'b2',
						'title': '首页1',
						'close': true
					}, {
						'id': 'b3',
						'title': '首页2',
						'close': true
					}],
					idKey: "id",
					textKey: "title",
					addApi: "suc2.json",
					onRemoveTab: function(obj, removeFun) {
						removeFun()
					}
				})
			})
		</script>
	</body>
</html>
